A data communication network may include multiple talkers (or sources of data) and multiple receivers. Any number of bridges may be connected in a daisy chain between each of the talkers and the receivers. The data communication network may be an arbitrary network (referred to as a non-engineered network) or non-arbitrary network (referred to as an engineered network). An arbitrary network may be, for example, a residential local area network (LAN), which may have different network devices (e.g., computers, cellular phones, televisions, printers, and electronic tablets) arbitrarily connecting and disconnecting at various points in the network and at random times. The network devices may connect and disconnect at any time regardless of the priority levels of data being transmitted in the arbitrary network. A non-arbitrary network may be, for example, an automotive network within a vehicle or a manufacturing assembly line network. In general, network devices in a non-arbitrary network are fixed and are not being connected and/or disconnected from the non-arbitrary network.
Network devices that are Institute of Electrical and Electronics Engineers (IEEE) 1588 standard (herein incorporated by reference in its entirety) compatible can support one-step or two-step clock precision time protocols (PTPs) to provide precise timing of transferred frames. During a data transfer event between two network devices operating according to the one-step clock PTP, a first network device may transmit an event message that includes a timestamp or other time information indicating when the event message is transmitted from the first network device to the second network device. In order for the event message to include the timestamp, a central processor of the first network device estimates a future time of day when the event message is to be transmitted from a port of a physical layer (PHY) of the first network device to the second network device. The estimated time is included in the event message when the event message is originally generated by the central processor. The estimated time can be inaccurate depending on delays associated with the PHY of the first network device. The central processor does not know an actual time that the event message is transmitted from the PHY of the first network device. As an alternative to estimating the future time of day, the central processor can build the event message and, prior to the PHY transmitting the event message to the second network device, the PHY can update time information in the event message to more accurately indicate the actual egress time of the event message. The one-step clock PTP refers to the transmission of the event message without transmission of a follow up message.
During a data transfer event between two network devices operating according to the two-step clock PTP, a PHY of a first network device may transmit an event message from an egress port of the first network device to the second network device. A timestamp (e.g., a binary counter value) of when the frame was transmitted to the second network device is determined by the PHY. The timestamp is stored in a register accessible by a central processor of the first network device. Once the frame egresses the egress port and the timestamp is generated, the central processor may receive an interrupt (a high overhead operation) from the PHY. The central processor can then read the register and obtain the timestamp. As an alternative, the central processor may poll the PHY to obtain the timestamp. The central processor then converts the timestamp to an actual time of day and generates a follow up message (‘FollowUp frame’) indicating the actual time of day that the event message was transmitted. The actual time of day determined by the central processor may be, for example, a 10 byte value that includes an upper 6 bytes representing an integer portion of a timestamp in seconds and a lower 4 bytes representing a fractional portion of the timestamp in nanoseconds. The FollowUp frame is then transmitted to the second network device. As an alternative, the FollowUp frame may be generated by the PHY. In order for the PHY to build the FollowUp frame, the PHY needs to store information included in the event message. This requires a large amount of gates in hardware and tends not to be feasible since PHYs are typically incapable of originating frames. The two-step clock PTP refers to the generation of the event message, and after determining the egress time of the event message, generation of the FollowUp frame.
Both the one-step clock PTP and the two-step clock PTP introduce a large amount of latency in a data path. The one-step clock PTP introduces latency in transmitting an event message from an egress port of a corresponding network device. Latency can be introduced when a central processor of the network device estimates a time when the event message is to be transmitted from the PHY. Latency can also be introduced by (i) delaying transmission of the event frame to allow the PHY to compute and convert a timestamp to a time of day, and (ii) modifying the event message to accurately indicate the time of day when the event message was transmitted. The two-step clock PTP introduces latency in transmitting a FollowUp message by having a PHY (i) store a timestamp in a register of when an event message was transmitted, and (ii) generate an interrupt indicating the timestamp has been stored. Latency is also introduced by having a central processor receive the interrupt and read the register (a slow operation). Latency can also be introduced when the central processor polls the PHY for the timestamp and the PHY transmits the timestamp to the central processor.
Also, both the one-step clock PTP and two-step clock PTP can exhibit increased latency if a large number of frames are stored in a queue to be egressed from a same egress port. For the one-step clock PTP, the central processor needs to be informed of (i) the number of frames stored in the queue, (ii) a delay until a particular event frame is to be transmitted, and/or (iii) a time when the event frame is to be transmitted. For a two-step clock PTP, the more frames stored in the queue, the more delayed a central processor may be in determining an egress time of an event frame, depending on where in the queue the event frame is stored.